/*
 * @Author: xuesong
 * @Date: 2022-06-07 16:15:46
 * @LastEditors: xuesong
 * @LastEditTime: 2022-06-08 20:11:53
 * @FilePath: \BLE_UART_EF\projects\ble_peripheral\uart_ble\userReadFlash\readFlash.h
 */

#ifndef __READ_FLASH_H__
#define __READ_FLASH_H__


#include "bcomdef.h"

#ifdef __cplusplus
extern "C"
{
#endif

typedef struct{
    uint32_t Addr;      // 
    uint16 len;         // read Len Byte Start with addr
}ReadFlash_infor_t;

typedef enum
{
    EF_OPTION_DEL,
    EF_OPTION_Read,
    EF_OPTION_SET,
}TEST_EF_OPTION;

typedef struct{
    char key[7];
    uint8 option;
    uint32 value;
}EF_test_str;

typedef enum
{
    B_READ_FLASH_FLAG_Init = 0x01,
}READ_FLASH_FLAG_BIT;

void SetReadFlashParament(uint8 *data,uint8 len);
uint16 ReadFlashAndPrint(void);
void SetReadEasyFlashParament(uint8 *data,uint8 len);
uint16 TestOptionEF(void);

#ifdef __cplusplus
}
#endif

#endif

